/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package modelo;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Embeddable;

/**
 *
 * @author Mike
 */
@Embeddable
public class ComentarioPK implements Serializable {
    @Basic(optional = false)
    @Column(name = "idComentario")
    private int idComentario;
    @Basic(optional = false)
    @Column(name = "idFase")
    private int idFase;

    public ComentarioPK() {
    }

    public ComentarioPK(int idComentario, int idFase) {
        this.idComentario = idComentario;
        this.idFase = idFase;
    }

    public int getIdComentario() {
        return idComentario;
    }

    public void setIdComentario(int idComentario) {
        this.idComentario = idComentario;
    }

    public int getIdFase() {
        return idFase;
    }

    public void setIdFase(int idFase) {
        this.idFase = idFase;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (int) idComentario;
        hash += (int) idFase;
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof ComentarioPK)) {
            return false;
        }
        ComentarioPK other = (ComentarioPK) object;
        if (this.idComentario != other.idComentario) {
            return false;
        }
        if (this.idFase != other.idFase) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "modelo.ComentarioPK[ idComentario=" + idComentario + ", idFase=" + idFase + " ]";
    }
    
}
